package com.myway.ibe.enums;

/**
 * Created by Administrator on 2018/1/22.
 */
public enum PassengerType {
    ADULT("ADULT"), CHILD("CHILD"), INFANT("INFANT");

    private final String alias;

    private PassengerType(String alias) {
        this.alias = alias;
    }

    public String getAlias() {
        return alias;
    }

    public static String convertString(String in[])
    {
        if (in!=null && in.length >0)
        {
            String out = "";
            for (String s  : in)
            {
                out = out + s + ",";
            }
            // remove the last ','
            if(out.endsWith(",")){out = out.substring(0, out.length()-1);}
            return out;
        }
        return null;
    }
}
